package com.schoolcloud.api.client;

import com.schoolcloud.common.model.R;
import com.schoolcloud.api.dto.FileInfoDTO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient("sc-file")
public interface FileClient {
    @GetMapping("file/info")
    R<FileInfoDTO> getFileInfo(@RequestParam String filePath);

    @GetMapping("file/check")
    R<Boolean> checkFileExist(@RequestParam String bucketName, @RequestParam String filePath);
    @PostMapping("file/upload/share/chunk/merge")
    public R<?> mergeChunk(@RequestParam String md5, @RequestParam String fileName, @RequestParam int chunkTotal);
}
